import { createReactive } from '../../vue'

const template = `
  <ul class="list">
    <h1>{{ title }}</h1>
    {{ dateTime }}
    <!-- 个人设置的标签for -->
    <for data="list" tag="li" class="item">
      <span>Name: { name }</span>
      <span>Age: { age }</span>
    </for>
  </ul>
`

function TestA() {
  const state = createReactive({
    title: '教师信息列表',
    dateTime: '2021-02-03 12:23',
    list: [
      {
        id: 1,
        name: '小明',
        age: 22
      }, {
        id: 2,
        name: '小红',
        age: 23
      }, {
        id: 3,
        name: '小英',
        age: 26
      }
    ]
  })

  return [template, state]
}

export default TestA